<template>
    <view style="page">
        <view class="swiper-wrap">
            <u-swiper height="100%" :list="list" keyName="url" :autoplay="false" imgMode="aspectFit" bgColor="#fff" :indicator="true" indicatorMode="dot" indicatorActiveColor="#12BAA4" indicatorInactiveColor="#ddd"></u-swiper>
            <!-- 颜色选择器 -->
            <view class="color-indicator">
                <view class=""></view>
            </view>
        </view>
        <!-- 参数板块 -->
        <view class="data-wrap">
            <view class="title">传祺GS3 POWER</view>
            <view class="desc">启辰D60EV 2019款</view>
            <view class="tags">
                <view class="tag">新能源电车</view>
            </view>
            <view class="price">市场指导价：¥14.8万/起</view>
            <view class="button">参数配置</view>
        </view>
        <!-- tabs -->
        <u-tabs :activeStyle="{color: '#12BAA4' }" lineColor="#12BAA4" :list="tabs" @click="click"></u-tabs>
        <!-- 内容区 -->
        <view class="content">

        </view>
        <!-- 按钮区 -->
        <view class="bottom_btns">
            <view class="button">分享好友</view>
            <view class="button">立即试驾</view>
        </view>
        <!-- 询问价格按钮 -->
        <view class="fixed-button">
            询问价格
        </view>
    </view>
</template>

<script>
export default {
    data() {
        return {
            list: [{
                url: 'https://cdn.uviewui.com/uview/resources/video.mp4',
                title: '昨夜星辰昨夜风，画楼西畔桂堂东',
                poster: 'https://cdn.uviewui.com/uview/swiper/swiper1.png'
            }, {
                url: 'https://cdn.uviewui.com/uview/swiper/swiper2.png',
                title: '身无彩凤双飞翼，心有灵犀一点通'
            }, {
                url: 'https://cdn.uviewui.com/uview/swiper/swiper3.png',
                title: '谁念西风独自凉，萧萧黄叶闭疏窗，沉思往事立残阳'
            }],
            tabs: [
                {
                    name: '车辆介绍',
                },
                {
                    name: '基础服务',
                },
                {
                    name: '增值服务',
                },
                {
                    name: '公司介绍',
                },
            ],
        };
    }
}
</script>

<style lang="scss" scoped>
.page {
    padding-bottom: 100upx;
}
.swiper-wrap {
    width: 100%;
    height: 455upx;
}
.data-wrap {
    width: 678upx;
    position: relative;
    margin: 20upx 36upx;
    background: #fff;
    border-radius: 16upx;
    padding: 32upx 36upx;
    box-sizing: border-box;

    .title {
        font-size: 28upx;
        font-weight: bold;
        color: #333;
    }

    .desc {
        font-size: 20upx;
        font-weight: bold;
        color: #999;
        margin-bottom: 29upx;
    }

    .tags {
        display: flex;

        .tag {
            padding: 0 14upx;
            line-height: 44upx;
            background: #12baa4;
            border-radius: 6upx;
            font-size: 20upx;
            font-weight: bold;
            color: #fff;
            margin-bottom: 20upx;
            & + & {
                margin-left: 10upx;
            }
        }
    }

    .price {
        font-size: 22upx;
        font-weight: bold;
        color: #ec4863;
    }

    .button {
        padding: 13upx 20upx;
        position: absolute;
        top: 37upx;
        right: 40upx;
        font-size: 24upx;
        font-weight: bold;
        color: #12baa4;
        border: 1px solid #bebebe;
        border-radius: 2px;
    }
}

.bottom_btns {
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: center;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 10;
    .button {
        flex: 1;
        line-height: 96upx;
        font-weight: bold;
    }
    .button:nth-child(1) {
        background: #fff;
        color: #666;
    }
    .button:nth-child(2) {
        background: #ec4863;
        color: #fff;
    }
}

.fixed-button {
    width: 128upx;
    height: 128upx;
    background: #fff;
    padding: 36upx;
    box-sizing: border-box;
    border-radius: 999upx;
    line-height: 29upx;
    font-size: 28upx;
    font-weight: bold;
    color: #ec4863;
    position: fixed;
    right: 57upx;
    bottom: 129upx;
}
</style>
